<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        div{
            width: 50px;
            height: 50px;
            background: #ccc;
        }
        .d1{
            margin-bottom: 20px;
        }
        .d2{
            margin-top: 30px;
        }

        .d3{
            width: 100px;
            height: 100px;
            background: blue;
            color: white;
            /* border: 1px solid red; */
            /* margin-top: 50px; */
        }
        
        .d4{
            margin-top: 20px;
        }
    </style>
</head>
<body>
    <!-- 情况1 -->
    <div class="d1"></div>
    <div class="d2"></div>
    <hr>

    <!-- 情况2 -->
    <div class="d3">
        <!-- aa -->
        <div class="d4"></div>
    </div>
</body>
</html>